package com.bfly.mall.wechat.minipro.dto;

import javax.xml.bind.annotation.XmlAccessType;
import javax.xml.bind.annotation.XmlAccessorType;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlRootElement;
import java.io.Serializable;

/**
 * 微信退款申请实体类
 *
 * @author 长沙商脉科技有限公司
 * @date 2020/12/11 11:12
 */
@XmlRootElement(name = "xml")
@XmlAccessorType(XmlAccessType.FIELD)
public class WeChatRefundOrder implements Serializable {

    private static final long serialVersionUID = -432173358420810034L;

    @XmlElement(name = "appid", required = true)
    private String appId;                    //微信分配的小程序ID

    @XmlElement(name = "mch_id", required = true)
    private String mchId;                    //微信支付分配的商户号

    @XmlElement(name = "nonce_str", required = true)
    private String nonceStr;                //随机字符串，不长于32位。推荐随机数生成算法

    @XmlElement(name = "sign", required = true)
    private String sign;                    //签名

    @XmlElement(name = "transaction_id",required = true)
    private String transactionId;           // 微信生成的订单号，在支付通知中有返回

    @XmlElement(name = "out_trade_no", required = true)
    private String outTradeNo;                //商户系统内部的订单号,32个字符内、可包含字母, 其他说明见商户订单号

    @XmlElement(name = "out_refund_no",required = true)
    private String outRefundNo;             //商户系统内部的退款单号，商户系统内部唯一，只能是数字、大小写字母_-|*@ ，同一退款单号多次请求只退一笔。

    @XmlElement(name = "total_fee", required = true)
    private int totalFee;                //订单总金额，单位为分，只能为整数

    @XmlElement(name = "refund_fee", required = true)
    private int refundFee;                //退款总金额，订单总金额，单位为分，只能为整数

    @XmlElement(name = "refund_desc")
    private String refundDesc;            //若商户传入，会在下发给用户的退款消息中体现退款原因 注意：若订单退款金额≤1元，且属于部分退款，则不会在退款消息中体现退款原因

    public String getTransactionId() {
        return transactionId;
    }

    public void setTransactionId(String transactionId) {
        this.transactionId = transactionId;
    }

    public String getOutRefundNo() {
        return outRefundNo;
    }

    public void setOutRefundNo(String outRefundNo) {
        this.outRefundNo = outRefundNo;
    }

    public String getAppId() {
        return appId;
    }

    public void setAppId(String appId) {
        this.appId = appId;
    }

    public String getMchId() {
        return mchId;
    }

    public void setMchId(String mchId) {
        this.mchId = mchId;
    }

    public String getNonceStr() {
        return nonceStr;
    }

    public void setNonceStr(String nonceStr) {
        this.nonceStr = nonceStr;
    }

    public String getSign() {
        return sign;
    }

    public void setSign(String sign) {
        this.sign = sign;
    }

    public String getOutTradeNo() {
        return outTradeNo;
    }

    public void setOutTradeNo(String outTradeNo) {
        this.outTradeNo = outTradeNo;
    }

    public int getTotalFee() {
        return totalFee;
    }

    public void setTotalFee(int totalFee) {
        this.totalFee = totalFee;
    }

    public int getRefundFee() {
        return refundFee;
    }

    public void setRefundFee(int refundFee) {
        this.refundFee = refundFee;
    }

    public String getRefundDesc() {
        return refundDesc;
    }

    public void setRefundDesc(String refundDesc) {
        this.refundDesc = refundDesc;
    }
}